import request from '@/utils/request'

export function getHouseSignList(params) {
    return request({
        url: '/admin6/house_signings',
        method: 'get',
        params
    })
}

export function deleteHouseSign(id) {
    return request({
        url: "/admin6/del_house_signing/" + id,
        method: 'DELETE',
    })
}

export function updHouseSign(data){
    if(!data.id){
        return request({
            url: "/admin6/add_house_signings/house",
            method: 'POST',
            data: data
        })
    }
    return request({
        url: "/admin6/upd_house_signing/house/" + data.id,
        method: 'PATCH',
        data: data
    })
}

export function updPostSign(data){
    if(!data.id){
        return request({
            url: "/admin6/add_house_signings/post",
            method: 'POST',
            data: data
        })
    }
    return request({
        url: "/admin6/upd_house_signing/post/" + data.id,
        method: 'PATCH',
        data: data
    })
}